
set(OPENGL_NAME uos-opengl)

set(INC_LIST 
    )
set(SRC_LIST
    src/main.cpp
    )

include(CheckIncludeFile)

check_include_file("GL/gl.h" HAVE_GL_H)
check_include_file("GL/freeglut.h" HAVE_GLUT_H)
if(NOT (HAVE_GLUT_H AND HAVE_GL_H))
    message(FATAL_ERROR 
        [[
            down load gl and glut
            apt get install freeglut3 freeglut3-dev libglew-dev mesa-utils
            sudo apt-get install libglew-dev glew-utils
        ]]
        )
endif()
add_executable(${OPENGL_NAME} 
    ${SRC_LIST}
    )
set_target_properties(${OPENGL_NAME}
    PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
    )
target_link_libraries(${OPENGL_NAME}
    PRIVATE GL
    PRIVATE glut
    PRIVATE GLU
    )




